-
Notifications
You must be signed in to change notification settings - Fork 23
feat: Add GraalVM native-image support by removing Guava shading #614
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
alexcol23
wants to merge
1
commit into
splitio:master
Choose a base branch
from
AdelanteFinancialHoldings:feature/graalvm-native-image-support
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
feat: Add GraalVM native-image support by removing Guava shading #614
alexcol23
wants to merge
1
commit into
splitio:master
from
AdelanteFinancialHoldings:feature/graalvm-native-image-support
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The shaded Guava (split.com.google.common.*) causes GraalVM native-image parsing errors because it lacks the native-image configuration that standard Guava provides. Problem: When building a native image with the Split SDK, GraalVM fails with: Error parsing split.com.google.common.cache.LocalCache$Segment Caused by: Unresolved type split.com.google.common.util.concurrent.SettableFuture Root cause: The Maven Shade Plugin relocates Guava to split.com.google.common.* which strips the META-INF/native-image configuration that standard Guava includes for GraalVM compatibility. Solution: Remove Guava from the shade plugin configuration. Guava remains as a transitive dependency, allowing applications to use the standard Guava library which has proper GraalVM native-image support. Changes: - Remove com.google.guava:guava from shade plugin includes - Remove org.checkerframework:* from shade plugin includes - Remove com.google -> split.com.google relocation - Remove org.checkerframework -> split.org.checkerframework relocation Impact: - Guava is now a transitive dependency instead of being bundled - Applications using GraalVM native-image can now build successfully - Potential version conflicts with other Guava users (mitigated by dependency management in build tools) Tested with: - Quarkus 3.27.1 + Mandrel JDK-23 - Native image builds successfully - Split client works correctly at runtime
alexcol23
pushed a commit
to AdelanteFinancialHoldings/splitio-java-client
that referenced
this pull request
Jan 14, 2026
This commit enables GraalVM native-image compilation for applications using the Split.io Java SDK. Problem: The Split SDK shades Guava to split.com.google.common.* to avoid dependency conflicts. However, this shaded Guava lacks the GraalVM native-image configuration that standard Guava provides, causing build failures with errors like: 'Discovered unresolved type: split.com.google.common.util.concurrent.SettableFuture' Root Cause: Standard Guava (com.google.common.*) includes GraalVM native-image configuration in META-INF/native-image/. When the SDK shades Guava to split.com.google.common.*, this configuration is lost. Solution: Remove Guava from the shade plugin configuration. Guava remains as a transitive dependency, allowing applications to use the standard Guava library which has proper GraalVM native-image support. Changes: - Remove com.google.guava:guava from shade plugin includes - Remove org.checkerframework:* from shade plugin includes - Remove com.google -> split.com.google relocation - Remove org.checkerframework -> split.org.checkerframework relocation - Update version to 4.18.2-graalvm to distinguish from upstream Testing: - Built native image with Quarkus 3.27.1 + Mandrel JDK-23 - Verified Split client works correctly at runtime - Tested feature flag resolution in native image Reference: splitio#614
andriperalt
pushed a commit
to AdelanteFinancialHoldings/splitio-java-client
that referenced
this pull request
Jan 23, 2026
This commit enables GraalVM native-image compilation for applications using the Split.io Java SDK. Problem: The Split SDK shades Guava to split.com.google.common.* to avoid dependency conflicts. However, this shaded Guava lacks the GraalVM native-image configuration that standard Guava provides, causing build failures with errors like: 'Discovered unresolved type: split.com.google.common.util.concurrent.SettableFuture' Root Cause: Standard Guava (com.google.common.*) includes GraalVM native-image configuration in META-INF/native-image/. When the SDK shades Guava to split.com.google.common.*, this configuration is lost. Solution: Remove Guava from the shade plugin configuration. Guava remains as a transitive dependency, allowing applications to use the standard Guava library which has proper GraalVM native-image support. Changes: - Remove com.google.guava:guava from shade plugin includes - Remove org.checkerframework:* from shade plugin includes - Remove com.google -> split.com.google relocation - Remove org.checkerframework -> split.org.checkerframework relocation - Update version to 4.18.2-graalvm to distinguish from upstream Testing: - Built native image with Quarkus 3.27.1 + Mandrel JDK-23 - Verified Split client works correctly at runtime - Tested feature flag resolution in native image Reference: splitio#614 (cherry picked from commit f756036)
andriperalt
added a commit
to AdelanteFinancialHoldings/splitio-java-client
that referenced
this pull request
Jan 23, 2026
* Init wofklow * feat: Add GraalVM native-image support by removing Guava shading This commit enables GraalVM native-image compilation for applications using the Split.io Java SDK. Problem: The Split SDK shades Guava to split.com.google.common.* to avoid dependency conflicts. However, this shaded Guava lacks the GraalVM native-image configuration that standard Guava provides, causing build failures with errors like: 'Discovered unresolved type: split.com.google.common.util.concurrent.SettableFuture' Root Cause: Standard Guava (com.google.common.*) includes GraalVM native-image configuration in META-INF/native-image/. When the SDK shades Guava to split.com.google.common.*, this configuration is lost. Solution: Remove Guava from the shade plugin configuration. Guava remains as a transitive dependency, allowing applications to use the standard Guava library which has proper GraalVM native-image support. Changes: - Remove com.google.guava:guava from shade plugin includes - Remove org.checkerframework:* from shade plugin includes - Remove com.google -> split.com.google relocation - Remove org.checkerframework -> split.org.checkerframework relocation - Update version to 4.18.2-graalvm to distinguish from upstream Testing: - Built native image with Quarkus 3.27.1 + Mandrel JDK-23 - Verified Split client works correctly at runtime - Tested feature flag resolution in native image Reference: splitio#614 (cherry picked from commit f756036) * feat: Configure GitHub Packages publishing with timestamp-based versioning - Update publish-branch workflow to use timestamp-based version format (BASE_VERSION-YYYYMMDD-HHMMSS) - Add github-release Maven profile with GitHub Packages distribution management - Update actions/setup-java from v3 to v5 and Java version from 11 to 19 - Revert version from 4.18.2-graalvm back to 4.18.2 in parent and client POMs - Improve workflow step naming for clarity * chore: Simplify CI workflow to run only on addi-release PRs with JDK 19 - Comment out push triggers and matrix JDK strategy (8, 11, 19) - Configure workflow to run only on pull requests to addi-release branch - Remove conditional logic from test and linter steps to run unconditionally - Comment out SonarQube scan steps for push and pull request events - Update publish-branch workflow quote style for consistency * chore: Restore standard CI workflow configuration and add CODEOWNERS - Restore push triggers for all branches - Restore pull request triggers for master and development branches - Restore JDK matrix strategy (8, 11, 19) with fail-fast disabled - Restore conditional logic for test and linter steps on JDK 8 - Restore SonarQube scan steps for push and pull request events - Add CODEOWNERS file with team ownership rules for Anywhere and Platform teams --------- Co-authored-by: emadronero <emadronero@addi.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR enables GraalVM native-image compilation for applications using the Split.io Java SDK.
Problem
The Split SDK shades Guava to
split.com.google.common.*to avoid dependency conflicts. However, this shaded Guava lacks the GraalVM native-image configuration that standard Guava provides, causing build failures:Root Cause
Standard Guava (
com.google.common.*) includes GraalVM native-image configuration inMETA-INF/native-image/. When the SDK shades Guava tosplit.com.google.common.*, this configuration is lost, and GraalVM cannot parse complex classes likeLocalCache.Segment.Solution
Remove Guava from the shade plugin configuration. Guava remains as a transitive dependency, allowing applications to use the standard Guava library which has proper GraalVM native-image support.
Changes
com.google.guava:guavafrom shade plugin includesorg.checkerframework:*from shade plugin includescom.google→split.com.googlerelocationorg.checkerframework→split.org.checkerframeworkrelocationTesting
Impact
Breaking Change
Applications that explicitly depend on the shaded Guava package names (
split.com.google.*) will need to update imports. However, this is unlikely since the shaded packages are internal implementation details.Benefits
Potential Risks
Related Frameworks
This fix enables Split SDK usage with:
Checklist